package com.netString;

import java.util.HashMap;
import java.util.Map;
import java.util.Scanner;
import java.util.StringTokenizer;

public class CountWord {

	public static void main(String[] args) 
	{
	   Scanner in = new Scanner(System.in);
	   String str = in.nextLine();
	   System.out.println(str);
	   count(str);

	}

	private static void count(String str) 
	{
		StringTokenizer sk = new StringTokenizer(str);
		HashMap<String, Integer> map = new HashMap<>();
		while(sk.hasMoreTokens())
		{
	       String t = sk.nextToken();
			
			map.put(t, map.get(t)==null ? 1:map.get(t)+1);
		}
		
		for(Map.Entry<String, Integer> entry : map.entrySet())
		{
			System.out.println(entry.getKey() + "  =  " +entry.getValue());
		}
		
	}

}
